<style type="text/css">
#box {
	background: #FFF;
	width: 238px;
	height: 410px;
	margin: -390px 0 0 0;
	display: block;
	border: solid 4px #D93600;
	position: absolute;
	z-index: 999;
	opacity: .5
}
.shopMenu {
	position: fixed;
	z-index: 1;
	right: 25%;
	top: 0;
}
</style>
<div class="squares" nc_type="current_display_mode">
    <input type="hidden" id="lockcompare" value="unlock" />
  {if(!empty($goods_common_list) && is_array($goods_common_list))}
  <ul class="list_pic">
    {volist name='goods_common_list' key='key' id='val'}
    <li class="item">
      <div class="goods-content" nctype_goods="{$val.goods_id}" nctype_store="{$val.store_id}">
        <script>
        		function padding_img(obj){
	        		var $this = obj,
	    					width = $this.naturalWidth,
	    					height = $this.naturalHeight,
	    					p = width/height,
	    					now_height = 225/p,
	    					padding_top = (225 - now_height)/2;
	    				$($this).css({
	    					'padding-top':padding_top+'px'
	    			});
	        	}
        </script>
        <div class="new_w100_ new_h225" style="box-sizing: border-box;">
        	<a href="{:url('index/goods/detail',['goods_id'=>$val['goods_id']])}" target="_blank" title="{$val.goods_name|default=''}">
	      		<img alt="{$val.goods_name}" src="{$val.goods_image|img_url=360}" class="goods_images" onload="padding_img(this)" style="width: 100%;height: auto;"/>
        	</a>
        </div>
        <div class="goods-info">
          <div class="goods-name" style="font-size: 13px;">
          	<a href="{:url('index/goods/detail',['goods_id'=>$val['goods_id']])}" target="_blank" title="{$val.goods_jingle}">{$val.goods_name|default=''}
          		<em>{$val.goods_jingle}</em>
          	</a>
          </div>
          <div class="goods-price">
          	<em class="sale-price new_c_main" title="商城价：￥{$val.goods_price}">￥{$val.goods_price}</em>
          	<em class="f13 fb new_ml5" style="color: #53514F;">{$val.goods_unit}</em>
          	<span class="new_f12 new_inline-block pull-right new_mr5" style="color: #53514F;">评分:<span style="color: #0066CC">{$val.evaluation_scores|default='5.0'}</span></span>
          </div>
          <div class="sell-stat">
            <ul>
              <li><a href="{:url('index/goods/detail',['goods_id'=>$val['goods_id']])}#ncGoodsRate" target="_blank" class="status">{$val.total_salenum|default=0}</a>
                <p>商品销量</p>
              </li>
              <li><a href="{:url('index/goods/common_comments',['goods_id'=>$val['goods_id']])}" target="_blank">{$val.evaluation_count|default=0}</a>
                <p>用户评论</p>
              </li>
              <li><em member_id="{$val.member_id}">&nbsp;</em></li>
            </ul>
          </div>
          <div class="add-cart">
            {if($val['goods_storage'] == 0)}
            	<a href="{:url('index/goods/detail',['goods_id'=>$val['goods_id']])}" ><i class="icon-bullhorn"></i>查看详情</a>
            {else /}
	         	<a href="javascript:void(0);" nctype="buy_now" data-param="{goods_id:<?php echo $val['goods_id'];?>}"><i class="icon-shopping-cart"></i>
	            	立即购买
	         	</a>
             <!-- <a href="javascript:void(0);" nctype="add_cart" data-param="{goods_id:<?php echo $value['goods_id'];?>}"><i class="icon-shopping-cart"></i>加入购物车</a> -->
            {/if}
          </div>
        </div>
      </div>
    </li>
    {/volist}
    <div class="clear"></div>
  </ul>
  {else /}
  <div id="no_results" class="no-results"><i></i>无商品记录</div>
  {/if}
</div>
<form id="buynow_form" method="post" action="{:url('member/buy/step2')}" target="_blank">
  <input id="goods_id" name="cart_id[]" type="hidden"/>
</form>
<script type="text/javascript" src="/old/data/resource/js/jquery.raty/jquery.raty.min.js?{$Think.config.url_base}"></script> 
<script type="text/javascript">
    $(document).ready(function(){
        $('.raty').raty({
            path: "/old/data/resorce/js/jquery.raty/img",
            readOnly: true,
            width: 80,
            score: function() {
              return $(this).attr('data-score');
            }
        });
    	initCompare();
    });
</script> 
